package address.model.dao;

import java.sql.SQLException;

import org.mybatis.spring.SqlSessionTemplate;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Repository;

import address.domain.Address;

@Repository
public  class AddressDAOMybatisImpl implements AddressDAO{
	
	
	@Autowired
	private SqlSessionTemplate session;

	@Override
	public Address selectAddressByDong(String id) throws SQLException{
		return session.selectOne(makeSqlId("selectAddressByDong"), id);
	}
	
	private String makeSqlId(String id){
		return "address.manager."+id;
	}


	
	
}
